package org.example.hotel.config;

import org.springframework.stereotype.Component;

@Component
public class SystemStatus {
    private boolean systemRunning = true;

    public synchronized void startSystem() {
        this.systemRunning = true;
    }

    public synchronized void stopSystem() {
        this.systemRunning = false;
    }

    public synchronized boolean isSystemRunning() {
        return systemRunning;
    }
}